put "Select,an,item,from,this,menu"&return&"hello,how,are,you" into items
put rect of me into temp
put HPopupMenu(items,0,item 4 of temp,(item 1 of temp)+1)
end mousedown
-- part contents for background part 5
----- text -----
HPopUpMenu
-- part contents for background part 6
----- text -----
The HPopupMenu XFCN allows you to create hierarchical popup menus.
This is freeware!
Guy de Picciotto.
CIS: 73300,3637
GENIE: G.PICCIOTTO
-- part contents for background part 7
----- text -----
Syntax:
IMPORTANT: this must be called from within a MOUSEDOWN handler!
HPopupMenu (<items>,<checkedItem>,<Top>,<Left>)
'items' contains the menu items. Menu items in the main menu are separated by a Return and items in a submenu are separated by a ',' . Only 2 levels of menus are allowed, this should be enough in most cases.
'CheckedItem' is the item in the main menu you want to be checked.
'Top' and 'left' are the coordinate where you want the menu to appear.
The function returns the menu line as the first item and the submenu line as the second item of the result. If the mouse is released outside of a menu, the function returns 0 (zero).